<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<meta name="viewport" content="width=device-width, initial-scale=1">
		<title>广告启动页</title>
		<link rel="stylesheet" href="../css/advertise.css">
		<!-- uni 的 SDK -->
		<script type="text/javascript" src="../js/webView.js"></script>
	</head>
	<body>
		<div class="content">
			<div class="con">
				<img id="img" class="enter" src="../imgs/bybrid.png">
			</div>
			<!-- 			<div class="title">
				e守护
			</div> -->
			<div class="input">
				<button type="button" class="inputButton">开启守护模式</button>
			</div>


			<div class="btn" id="timer">
				<div id="info">跳过</div>
				<div class="circleProgress_wrapper btn">
					<div class="wrapper right">
						<div class="circleProgress rightcircle"></div>
					</div>
					<div class="wrapper left">
						<div class="circleProgress leftcircle"></div>
					</div>
				</div>
			</div>
		</div>
	</body>
	<script>
		document.addEventListener('UniAppJSBridgeReady', function() {
			document.querySelector('.btn').addEventListener('click', function(e) {
				if (e.isTrusted) {
					plus.webview.currentWebview().close();
				}
			});

			// 广告点击跳转app内页
			document.querySelector('.input').addEventListener('click', function(e) {
				if (e.isTrusted) {
					plus.webview.currentWebview().close();
					uni.switchTab({
						url: '/pages/index/index',
					});
					console.log('跳转');
				}
			});
		});
	</script>
</html>
